package com.jlp.agents.agent.client;

public class MessageBuilder {

	StringBuilder builder ;
	final static String SEPARATOR ="|";
	public MessageBuilder(long timeStamp){
		builder = new StringBuilder();
		builder.append(timeStamp);
		
	}
	public void setType(String type){
		
	}
	public void setGroupName(String groupName){
		builder.append("g_=");
		builder.append(groupName);
	}
	public void putCounter(String key, long value){
		builder.append(SEPARATOR);
		builder.append(key);
		builder.append("=");
		builder.append(value);
	}
	public IMessage getMessage(){
		AgentMessage message=new AgentMessage();
		message.setMessage(builder.toString());
		return message;
		
	}
}
